﻿//using System;
//using System.Collections.Generic;
//using System.Linq;
//using System.Web;
//using System.Web.Mvc;
//using Framework.Authority;
//using Framework.Castle.Windsor;
//using Framework.Mvc.Util;

//namespace Framework.Mvc.Controllers
//{
//    public class AppController : AuthorityBaseController
//    {

//        #region  toolbar 相关
//        /// <summary>
//        /// 
//        /// </summary>
//        /// <returns></returns>
//        [HttpPost]
//        public override ActionResult Delete()
//        {
//            var app = new SysApp();
//            app.AppName = RequestExtention.GetString("appName");
//            app.AppOpTime = DateTime.Now;
//            app.AppStatus = 0;
//            Auth.Add(app);
//            return Json(new { id = 1 });
//        }
//        #endregion


//        /// <summary>
//        /// 
//        /// </summary>
//        /// <returns></returns>
//        public override ActionResult GridJson()
//        {
//            int count;
//            var list = Auth.GetApp(GridPageSize, GridPageIndex, out count);
//            return new EasyUIGridJsonResult(count, list);
//        }


//        public override ActionResult GridHead()
//        {
//            return View();
//        }


//        public override ActionResult DetailJson()
//        {
//            var app = Auth.GetApp(RequestExtention.GetInt("appID"));
//            return Json(app);
//        }

//        public override ActionResult Detail()
//        {
//            return View(new SysApp());
//        }

//        public override ActionResult Edit()
//        {
//            var app = new SysApp();
//            app.AppName = RequestExtention.GetString("appName");
//            app.AppOpTime = DateTime.Now;
//            app.AppStatus = 0;
//            app.AppID = RequestExtention.GetInt("appID");
//            if (app.AppID > 0)
//                return this.Success(Auth.Update(app));
//            return this.Success(Auth.Add(app));
//        }
//    }
//}
